import request from "../utils/axios/index";
export const add = (data) => request.post("article", data);

export const getListApi = () => request.get("article");

export const getArticleApi = (id) => request.get(`article/${id}`);

// 删除
export const deleteArticleApi = (id) => request.delete(`article/${id}`);

// 修改
export const updateArticleApi = (id, data) =>
  request.put(`article/${id}`, data);
